package cemp.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * @TableName stock_bk_main_current
 */
@Data
@TableName(value ="stock_bk_main_current")
public class StockBkMainCurrent implements Serializable {
    @TableId(value = "id",type = IdType.AUTO)
    private Integer id;

    private String bkCode;

    private String bkName;

    private BigDecimal priceCurrent;

    private BigDecimal priceUpAmount;

    private BigDecimal priceUpRatio;

    private BigDecimal amount;

    private BigDecimal trunover;

    private BigDecimal priceYesterday;

    private BigDecimal priceBegin;

    private BigDecimal priceMax;

    private BigDecimal priceMin;

    private Date staDatetime;

    private static final long serialVersionUID = 1L;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getBkCode() {
        return bkCode;
    }

    public void setBkCode(String bkCode) {
        this.bkCode = bkCode;
    }

    public String getBkName() {
        return bkName;
    }

    public void setBkName(String bkName) {
        this.bkName = bkName;
    }

    public BigDecimal getPriceCurrent() {
        return priceCurrent;
    }

    public void setPriceCurrent(BigDecimal priceCurrent) {
        this.priceCurrent = priceCurrent;
    }

    public BigDecimal getPriceUpAmount() {
        return priceUpAmount;
    }

    public void setPriceUpAmount(BigDecimal priceUpAmount) {
        this.priceUpAmount = priceUpAmount;
    }

    public BigDecimal getPriceUpRatio() {
        return priceUpRatio;
    }

    public void setPriceUpRatio(BigDecimal priceUpRatio) {
        this.priceUpRatio = priceUpRatio;
    }

    public BigDecimal getAmount() {
        return amount;
    }

    public void setAmount(BigDecimal amount) {
        this.amount = amount;
    }

    public BigDecimal getTrunover() {
        return trunover;
    }

    public void setTrunover(BigDecimal trunover) {
        this.trunover = trunover;
    }

    public BigDecimal getPriceYesterday() {
        return priceYesterday;
    }

    public void setPriceYesterday(BigDecimal priceYesterday) {
        this.priceYesterday = priceYesterday;
    }

    public BigDecimal getPriceBegin() {
        return priceBegin;
    }

    public void setPriceBegin(BigDecimal priceBegin) {
        this.priceBegin = priceBegin;
    }

    public BigDecimal getPriceMax() {
        return priceMax;
    }

    public void setPriceMax(BigDecimal priceMax) {
        this.priceMax = priceMax;
    }

    public BigDecimal getPriceMin() {
        return priceMin;
    }

    public void setPriceMin(BigDecimal priceMin) {
        this.priceMin = priceMin;
    }

    public Date getStaDatetime() {
        return staDatetime;
    }

    public void setStaDatetime(Date staDatetime) {
        this.staDatetime = staDatetime;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        StockBkMainCurrent other = (StockBkMainCurrent) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getBkCode() == null ? other.getBkCode() == null : this.getBkCode().equals(other.getBkCode()))
            && (this.getBkName() == null ? other.getBkName() == null : this.getBkName().equals(other.getBkName()))
            && (this.getPriceCurrent() == null ? other.getPriceCurrent() == null : this.getPriceCurrent().equals(other.getPriceCurrent()))
            && (this.getPriceUpAmount() == null ? other.getPriceUpAmount() == null : this.getPriceUpAmount().equals(other.getPriceUpAmount()))
            && (this.getPriceUpRatio() == null ? other.getPriceUpRatio() == null : this.getPriceUpRatio().equals(other.getPriceUpRatio()))
            && (this.getAmount() == null ? other.getAmount() == null : this.getAmount().equals(other.getAmount()))
            && (this.getTrunover() == null ? other.getTrunover() == null : this.getTrunover().equals(other.getTrunover()))
            && (this.getPriceYesterday() == null ? other.getPriceYesterday() == null : this.getPriceYesterday().equals(other.getPriceYesterday()))
            && (this.getPriceBegin() == null ? other.getPriceBegin() == null : this.getPriceBegin().equals(other.getPriceBegin()))
            && (this.getPriceMax() == null ? other.getPriceMax() == null : this.getPriceMax().equals(other.getPriceMax()))
            && (this.getPriceMin() == null ? other.getPriceMin() == null : this.getPriceMin().equals(other.getPriceMin()))
            && (this.getStaDatetime() == null ? other.getStaDatetime() == null : this.getStaDatetime().equals(other.getStaDatetime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getBkCode() == null) ? 0 : getBkCode().hashCode());
        result = prime * result + ((getBkName() == null) ? 0 : getBkName().hashCode());
        result = prime * result + ((getPriceCurrent() == null) ? 0 : getPriceCurrent().hashCode());
        result = prime * result + ((getPriceUpAmount() == null) ? 0 : getPriceUpAmount().hashCode());
        result = prime * result + ((getPriceUpRatio() == null) ? 0 : getPriceUpRatio().hashCode());
        result = prime * result + ((getAmount() == null) ? 0 : getAmount().hashCode());
        result = prime * result + ((getTrunover() == null) ? 0 : getTrunover().hashCode());
        result = prime * result + ((getPriceYesterday() == null) ? 0 : getPriceYesterday().hashCode());
        result = prime * result + ((getPriceBegin() == null) ? 0 : getPriceBegin().hashCode());
        result = prime * result + ((getPriceMax() == null) ? 0 : getPriceMax().hashCode());
        result = prime * result + ((getPriceMin() == null) ? 0 : getPriceMin().hashCode());
        result = prime * result + ((getStaDatetime() == null) ? 0 : getStaDatetime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", bkCode=").append(bkCode);
        sb.append(", bkName=").append(bkName);
        sb.append(", priceCurrent=").append(priceCurrent);
        sb.append(", priceUpAmount=").append(priceUpAmount);
        sb.append(", priceUpRatio=").append(priceUpRatio);
        sb.append(", amount=").append(amount);
        sb.append(", trunover=").append(trunover);
        sb.append(", priceYesterday=").append(priceYesterday);
        sb.append(", priceBegin=").append(priceBegin);
        sb.append(", priceMax=").append(priceMax);
        sb.append(", priceMin=").append(priceMin);
        sb.append(", staDatetime=").append(staDatetime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}
